#!/bin/bash

{% for ip in groups.zk %}
{% if ip == inventory_hostname %}
echo {{ loop.index }} > {{zk_data_dir}}/myid
{% endif %}
{% endfor %}
